//
//  BtnCollectionViewCell.swift
//  GFWB
//
//  Created by iSolar on 2017/4/18.
//  Copyright © 2017年 iSolar. All rights reserved.
//

import UIKit

class BtnCollectionViewCell: UICollectionViewCell {

    @IBOutlet weak var img: UIImageView!
    
    @IBOutlet weak var label: UILabel!
    
    @IBOutlet weak var btn: UIButton!
    
    //MARK:- 定义属性
    var image: UIImage?{
        didSet {
            if image != nil {
                img.image = image
            } else {
                img.image = nil;
            }
        }
    }
    
    //MARK:- 事件的监听
    @IBAction func btnClick(_ sender: UIButton) {
        NotificationCenter.default.post(name: Notification.Name(rawValue: BtnNote), object: nil)
    }
    
}
